The present invention relates to a storage apparatus such as a magnetic disk apparatus etc. and in particular to a storage apparatus for recording and reproducing real-time data such as a image data by controlling a temporary memory circuit built into the storage apparatus and an input/output (I/O) control method for such a storage apparatus.
In recent years, the recording density and the data transfer rate in storage apparatus, such as magnetic disk apparatus, have been ever on the increase. These disk apparatuses are used also for recording and reproducing multi-channel image data.
For image data to be continuously recorded or reproduced at a predetermined rate in a disk apparatus, it is necessary to process an I/O request within a predetermined time in the disk apparatus. Processing a plurality of I/O requests requires accurate time management of each I/O request.
The time management of the I/O requests can be executed by software processing of a host computer for controlling the disk apparatus. Managing I/O requests in real time, however, produces the problem of a heavy load imposed on the CPU. In view of this, as disclosed in unexamined Japanese publication Hei 8-171526, a dedicated interface unit is connected between the disk apparatus and the host computer for time management of I/O requests.
Further, in recording or reproducing multi-channel image data, a temporary memory unit is required to buffer data that would otherwise be lost due to the suspension of data transfer mechanical operations such as the disk apparatus seek operation.
Conventional disk apparatuses, as disclosed in U.S. patent Ser. No. 5,465,343, for example, comprise a temporary memory circuit for improving the storage performance, in which a temporary memory circuit is used as a buffer memory or a cache memory. The temporary memory circuit is used also for prefetching. The prefetching is a process for reading a succeeding data after reading data corresponding to an output request, and storing the succeeding data in the temporary memory unit with the aim of improving the performance of processing sequential data I/O requests.
The conventional storage apparatus using the above-mentioned interface unit and disk apparatus will now be explained with reference to the accompanying drawings.
FIG. 39 is a block diagram showing a general system configuration of the storage apparatus using the above-mentioned interface unit and the conventional disk apparatus. As shown in FIG. 39, a host computer 71, a reference clock generating section 72 and an interface unit 73 are connected to an I/O bus 75. A disk apparatus 74 is connected to the interface unit 73 through a data bus 76.
The interface unit 73 includes a bus interface control section 82 (hereinafter called xe2x80x9cthe bus I/F control section 82xe2x80x9d), an I/O control section 84, a schedule management section 81 and a queue-with-priority management section 83. In the interface unit 73, the schedule management section 81 controls the sequence of execution of I/O requests.
The host computer 71 issues a data I/O request to the interface unit 73. The I/O request is received through the I/O bus 75 by the I/F control section 82 of the interface unit 73, and stored in the queue-with-priority management section 83 through a command bus 73. The queue-with-priority management section 83 manages a queue with priority, a pending queue and an I/O execution queue.
The reference clock information generated in the reference clock generating section 72 passes on the I/O bus 75, and is stored in the schedule management section 81 through the bus I/F control section 82.
The schedule management section 81 transfers an I/O request to the queue with priority in the queue-with-priority management section 83. Upon receipt of the request, the schedule management section 81 determines whether the queue with priority contains an I/O request.
In the case where the queue with priority contains an I/O request, the schedule management section 81 fetches the particular I/O request and determines whether the request has a high order of priority with a specified processing time. In the case where the request has a high priority, the schedule management section 81 transfers the particular I/O request to the I/O control section 84, while in the case where the priority of the request is low, the schedule management section 81 adds the request to the pending queue.
In the case where no I/O request is contained in the queue with priority, in contrast, the pending queue is checked. In the presence of any I/O request contained in the pending queue, the particular I/O request is fetched and, when it is before the lapse of a set processing time, the fetched I/O request is executed. In the case where the I/O request has passed the set processing time and has timed out, on the other hand, the request is discarded or returned to the pending queue.
The I/O control section 84 controls the disk apparatus 74, accesses an instruction on data I/O, and executes the data write or read operation.
FIG. 40 is a diagram showing a method for dividing and controlling the buffer memory making up the temporary memory unit of the disk apparatus 314.
A portion (a) in FIG. 40 shows an adaptive segmentation method. As shown in the portion (a) of FIG. 40, the buffer memory is divided into a plurality of segments which can be assigned to a write buffer and a cache for read data. Also, each segment size can be changed in accordance with the data size to be transferred in response to a write/read command.
A portion (b) in FIG. 40 shows a fixed segmentation method. In response to a set command from an external system, the buffer memory can be divided into a plurality of segments of fixed size. With the disk apparatus conforming to the SCSI-3 (SCSI: Small Computer System Interface) specification, for example, the number of segments and the size of each segment of the buffer memory can be set appropriately. Each segment size is identical and fixed.
In the above-mentioned conventional control method, the disk apparatus 74 uses the buffer memory divided into segments. As a result, the conventional storage apparatus meets the multi-task requirement in the recording and reproduction of multi-channel image data, and improves storage performance.
Explanation will be made below about certain problems encountered in the conventional storage apparatus configured as described above.
A first problem of the conventional storage apparatus lies in the management of the execution time of an I/O request.
The time for executing an I/O request in the disk apparatus of the conventional storage apparatus is sometimes considerably variable depending on the variations in the time for access to a target area, i.e., the seek time or the waiting time for rotation and the operating conditions of the temporary memory circuit. In the conventional storage apparatus having the above-mentioned configuration, the interface unit and the external system lack means for obtaining information on the time for accessing the disk apparatus and the operating conditions of the temporary memory circuit, and therefore the execution time cannot be accurately predicted. As a result, a time management assuming an excessively long execution time is required for meeting a time limit to ensure that data is not lost, thereby leading to the problem of a deteriorated processing efficiency.
A second problem of the conventional storage apparatus is that the response to an I/O request is occasionally delayed because of deteriorated performance.
In the conventional storage apparatus, an I/O request with high-priority having a time limit is executed preferentially, while an I/O request low in priority is set in pending. In this way, the image data having high-priority are continuously recorded and reproduced. In the case where a high-priority I/O request is not contained in the queue but only low-priority I/O requests are pending, the I/O requests of low priority are executed unconditionally.
Consequently, even in the case where a high-priority I/O request is applied from an external system such as a host computer during the execution of a low-priority I/O request, the high-priority I/O request cannot be executed before complete execution of the low-priority I/O request. In such a case, the external system is not informed of the reason that the high-priority I/O request therefrom is not executed immediately and is required to wait until complete execution of the low-priority I/O request.
In other words, in the conventional storage apparatus, the time management does not take the execution time of I/O requests into consideration. As a result, when a high-priority I/O request is input, the high-priority I/O request is sometimes required to wait for execution.
Assume, on the other hand, that an I/O request of an image high in priority with a time limit for execution is input in the presence of an I/O request for random data, low in priority, without any time limit for waiting in queue. In such a case, the I/O request for an image is executed in priority even in the case where a time margin exists, sometimes considerably delaying the response to the I/O request for the random data.
Still another problem of the conventional disk apparatuses is that of inefficient use of the temporary memory circuit.
For continuous recording and reproduction to be assured in the disk apparatus for the image data, high in transfer rate, a number of temporary memory circuits are required. Image data or program data low in transfer rate, however, can be processed in a smaller number of memory circuits. Generally, the image data are continuous and sequential, while the program data are discrete. The method of controlling the buffer memory/cache memory varies depending on properties of the data.
The method of using the temporary memory circuit for the conventional disk apparatus is configured to meet the requirements of arbitrary data. The conventional method, however, is not suitable for assuring continuous recording and reproduction, or improving the storage performance of image data. In the case of repeat play of image data, for example, a wasteful prefetch operation occurs, and thereby the response is sometimes delayed and the performance is deteriorated.
In recording or reproducing multi-channel data containing image data, the size and the control method of the temporary memory circuit is required to be determined in accordance with the transfer rate, the real-time requirement, the continuity, etc. of each channel. Nevertheless, the conventional disk apparatus, of which the buffer memory can be divided into a plurality of segments or of which the segment size can be changed, cannot set the multi-channel data to correspond with each segment, for each channel, and therefore cannot set the segment size and the control method for each channel in accordance with different transfer rates, the real-time requirement or the continuity.
An object of the present invention is to provide a storage apparatus which, in order to solve the problem of delay in processing an I/O request, predicts the execution time of each I/O request from an external system and thereby assures an accurate processing of the I/O request. Another object of the present invention is to provide a storage apparatus and an I/O control method which can assure an accurate continuous recording and reproduction of image data or other data of high priority and which can efficiently process I/O requests of low priority. Still another object of the present invention is to provide a storage apparatus which can selectively execute an I/O request for random data, low in priority, which has a time limit for processing.
In order to achieve the above-mentioned objects, according to one aspect of the present invention, there is provided a storage apparatus comprising input means supplied with a request for predicting the I/O execution time from an external system, and a determining means for predicting the execution time of an I/O request in response to the request for the I/O execution time prediction.
With the above-mentioned configuration, the storage apparatus according to the present invention can correctly predict the execution time in response to an I/O request and can secure the execution time for the I/O request in response to an external system.
According to another aspect of the present invention, there is provided a storage apparatus comprising determining means for predicting the execution time in response to an I/O request from an external system and determining whether the predicted execution time can be realized within a time limit set by the external system, and an I/O request processing means for executing the I/O request in the case where the I/O request is determined to be executable by the determining means and for terminating the processing in the case where the I/O request is determined as not to be executable, thereby giving a response to the external system based on the result of the determination.
According to still another aspect of the invention, there is provided a storage apparatus further comprising determining means for giving a response to an I/O data transfer amount request from the external system including a data size for which the storage apparatus is capable of transferring within a time limit preset by the external system.
With the above-mentioned configuration, the storage apparatus according to the present invention can predict and respond to a data size capable of being input or output within a time limit, so that the apparatus can assure the execution time for a high-priority request while providing a maximum transfer rate for a low-priority request, thereby improving the processing efficiency. Also, the storage apparatus according to the present invention permits an external system such as a host computer to determine whether or not an I/O request can be executed within a time limit, and therefore can assure the execution completion time for each data I/O operation and can thus easily execute the real-time management of I/O requests.
According to a further aspect of the present invention, there is provided a storage apparatus comprising a temporary memory circuit capable of being divided into a plurality of segments according to the type of I/O request, wherein the determining means gives an available size of a corresponding segment as a writable data size in response to a write size request from an external system.
According to a still further aspect of the present invention, there is provided a storage apparatus comprising a temporary memory circuit capable of being divided into a plurality of segments in accordance with the type of I/O request, and a preread means for reading data from a designated area of a recording medium and storing the data temporarily in a corresponding segment, wherein an available size of a corresponding segment is offered as a data size capable of being preread in response to a preread size request, and a preread data size of a corresponding segment is offered as a readable data size in response to a read size request.
With the above-mentioned configuration, the storage apparatus according to the present invention offers an available size of a corresponding segment in response to a write data transfer amount request, offers a preread data size in response to a read data transfer amount request, and offers an available size of a corresponding segment in response to a preread data transfer amount request, wherein the I/O data can always be transferred in bursts and the time management of I/O requests can be accurately facilitated. Also, the present invention has the effect of shortening the time during which an I/O bus is occupied.
According to a yet further aspect of the present invention, there is provided an I/O control method for a storage apparatus comprising notification means for notifying the continuously-transferable amount of data to an external system in response to a data transfer amount request from the external system, in which a method of data transfer between the external system and the storage apparatus is selected in accordance with the transferable data amount. With this configuration, the I/O control method according to the present invention can always continuously transfer the I/O data.
According to still another aspect of the present invention, there is provided a storage apparatus, which identifies the type of I/O requests accumulated, and in the case where an I/O request is one with a time limit, the apparatus executes a type of an I/O request selectively in accordance with the time length remaining before a deadline which is calculated based on the time limit.
According to a further aspect of the present invention, there is provided a storage apparatus which calculates the time remaining before a deadline based on the time limit for accumulated I/O requests and selects the I/O request with the minimum remaining time among the accumulated I/O requests. In the case where the remaining time of the data request is smaller than a predetermined value, the apparatus executes the particular I/O request while in the case where the above-mentioned condition fails to be met, the apparatus executes the accumulated I/O requests by selecting the sequence of execution in accordance with a data recording position corresponding to each I/O request.
With the above-mentioned configuration, the storage apparatus according to the present invention, in which an I/O request is selected for execution based on the time remaining before a deadline, the apparatus can first assure the continuous recording and reproduction of image data or the like and then can assign the processing time to the recording and reproduction of random data, thereby improving the storage performance.
Another object of the present invention is to provide a storage apparatus for recording and reproducing image data by a method of controlling a temporary memory circuit suitable for image data in order to solve the above-mentioned problem of efficient use of the temporary memory circuit. Still another object of the present invention is to provide a storage apparatus in which a temporary memory circuit can be divided into a plurality of segments in accordance with a required number of channels, and in which the size and the method of controlling the temporary memory circuit can be set in accordance with a transfer rate and a real-time processing requirement of each channel.
In order to achieve the above-mentioned objects, according to one aspect of the present invention, there is provided a storage apparatus comprising a management information memory means for storing the file management information corresponding to the data recorded in a recording medium, wherein the management information is reproduced in response to an auto read request from an external system, and wherein the position on the recording medium where the location of a data block to be transferred to the external system is stored is determined, and the data block is preread.
According to another aspect of the present invention, there is provided a storage apparatus comprising a preread means for reproducing data blocks from a recording medium in response to a plurality of preread requests having an identifier from external system and transferring the data blocks to a temporary memory circuit, wherein in the case where an I/O request with an identifier is received from an external system, a data block is selected from among those preread in accordance with the identifier and transferred to the external system.
According to still another aspect of the present invention, there is provided a storage apparatus, in which the type of accumulated write data requests is identified and the data amount to be recorded continuously in a recording medium is selected and recorded, and in which the number of requests to be accumulated is selected by identifying the types of the accumulated read data requests thereby reproducing the data continuously from the recording medium in accordance with the number of the accumulated requests.
According to yet another aspect of the present invention, there is provided a storage apparatus comprising a prefetch means for transferring the data reproduced from a recording medium to a temporary memory circuit, wherein the type of each I/O request from the external system is identified, and one of a plurality of prefetch methods having different data amounts to be prefetched and different time lengths required for the prefetch processing is selected and executed in accordance with the type of a particular I/O request.
With this configuration, the storage apparatus according to the present invention can realize a method of controlling the temporary memory circuit suitable for transfer of image data, and a significant effect of an improved performance is attained as a result of a reduced load of transfer processing of the external system and an improved efficiency of the data recording and reproducing operation of the storage apparatus.
In order to achieve the above-mentioned objects, according to one aspect of the present invention, there is provided a storage apparatus comprising a temporary memory circuit divisible into a plurality of segments, and a temporary memory circuit control means for selecting a segment based on the information for identifying the write/read request from an external system and causing the write/read data to be temporarily stored in the selected segment.
According to another aspect of the present invention, there is provided a storage apparatus comprising a temporary memory circuit divisible into a plurality of segments, and a temporary memory circuit control means for determining a segment size, a method of data transfer from an external system and a method of data transfer to a recording medium for each segment based on the setting information supplied from the external system, selecting a segment based on the information for identifying the write/read request from the external system, and controlling the data transfer from the external system and the data transfer to the recording medium by the transfer method thus determined.
According to still another aspect of the present invention, there is provided a storage apparatus wherein the conditions for starting and stopping the data transfer between an external system and a corresponding segment, the conditions for starting and stopping the data transfer to and from the recording medium, the order of priority of data transfer to and from the recording medium and the unit of access from the external system, are determined on the basis of the setting information supplied from the external system.
According to yet another aspect of the present invention, there is provided a storage apparatus, wherein a recording/reproducing area for writing a data of a corresponding segment in a recording medium or for reading a data stored in a corresponding segment from a recording medium is set on the basis of the setting information supplied from the external system.
With this configuration of the storage apparatus according to the present invention, a data size and a transfer method are set for each segment based on the setting information from the external system, and the data transfer from and to the external system and from and to the recording medium are controlled by the transfer method thus set, making it possible to set different memory sizes and different control methods corresponding to different transfer rates, image data having real-time processing requirement, or the requirement of data other than the image data.
According to a further aspect of the present invention, there is provided a storage apparatus, wherein the unit of access to the segments from an external system is set by the setting information from an external system thereby to permit the external system to access the segments with smaller than a normal access unit for an improved random access efficiency.
According to a still further aspect of the present invention, there is provided a storage apparatus, wherein different storage areas are set for different segments based on the setting information supplied from an external system, and in this way one-to-one correspondence can be established between the storage areas and the segments, thereby guaranteeing the identity between the data in each segment and the data on the disk.
While the novel features of the invention are set forth particularly in the appended claims, the invention, both as to organization and content, will be better understood and appreciated, along with other objects and features thereof, from the following detailed description taken in conjunction with the drawings.